import Layout from '@/layout/basic/index'

export default [
  {
    path: '/wel',
    component: Layout,
    redirect: '/wel/index',
    children: [
      {
        path: 'index',
        name: '首页',
        meta: { i18n: 'dashboard' },
        component: () => import(/* webpackChunkName: "views" */ '@/views/wel/index')
      },
      {
        path: '/info/index',
        name: '个人信息',
        meta: { i18n: 'info' },
        component: () => import(/* webpackChunkName: "base" */ '@/views/system/userinfo')
      }
    ]
  },
  {
    path: '/work/process/leave',
    component: Layout,
    redirect: '/work/process/leave/form',
    children: [
      {
        path: 'form/:processDefinitionId',
        name: '请假流程',
        meta: { i18n: 'work' },
        component: () => import(/* webpackChunkName: "views" */ '@/views/work/process/leave/form')
      },
      {
        path: 'handle/:taskId/:processInstanceId/:businessId',
        name: '处理请假流程',
        meta: { i18n: 'work' },
        component: () => import(/* webpackChunkName: "views" */ '@/views/work/process/leave/handle')
      },
      {
        path: 'detail/:processInstanceId/:businessId',
        name: '请假流程详情',
        meta: { i18n: 'work' },
        component: () => import(/* webpackChunkName: "views" */ '@/views/work/process/leave/detail')
      }
    ]
  },
  {
    path: '/work/process/test',
    component: Layout,
    redirect: '/work/process/test/form',
    children: [
      {
        path: 'form/:processDefinitionId',
        name: '测试流程',
        meta: { i18n: 'work' },
        component: () => import(/* webpackChunkName: "views" */ '@/views/work/process/test/form')
      },
      {
        path: 'handle/:taskId/:processInstanceId/:businessId',
        name: '处理测试流程',
        meta: { i18n: 'work' },
        component: () => import(/* webpackChunkName: "views" */ '@/views/work/process/test/handle')
      },
      {
        path: 'detail/:processInstanceId/:businessId',
        name: '测试流程详情',
        meta: { i18n: 'work' },
        component: () => import(/* webpackChunkName: "views" */ '@/views/work/process/test/detail')
      }
    ]
  },
  {
    path: '/workflow',
    component: Layout,
    children: [
      {
        path: 'design/process/:id',
        name: '流程设计',
        component: () => import(/* webpackChunkName: "views" */ '@/views/plugin/workflow/design')
      },
      {
        path: 'design/model/history/:id',
        name: '模型历史',
        component: () => import(/* webpackChunkName: "views" */ '@/views/plugin/workflow/design/model-history')
      },
      {
        path: 'design/form/history/:id',
        name: '表单历史',
        component: () => import(/* webpackChunkName: "views" */ '@/views/plugin/workflow/design/form-history')
      },
      {
        path: 'process/start/:params',
        name: '新建流程',
        component: () => import(/* webpackChunkName: "views" */ '@/views/plugin/workflow/process/components/form')
      },
      {
        path: 'process/detail/:params',
        name: '流程详情',
        component: () => import(/* webpackChunkName: "views" */ '@/views/plugin/workflow/process/components/detail')
      }
    ]
  }
]
